Uber and Lyft have won a major victory in their battle to continue classifying drivers as contractors, not employees, following the passage of a ballot measure that exempts them from a California labor law.

On Tuesday, voters in California passed Proposition 22, the most expensive ballot-measure campaign in state history, which came to symbolize a bitter struggle over the future of the gig economy.

Roughly 58% of ballots were cast in favor. The measure was backed by some of Silicon Valley’s most powerful tech companies, including Uber, Lyft, Instacart and DoorDash, which spent upwards of $200m on the efforts.